<?php
/**
 * "Magically" called when PHP doesn't find a class (see: {@link http://php.net/autoload "autoloading objects"} in the PHP manual).
 * For this implementation of an autoloader, the classname is 
 * supposed to carry the path information in it like so: PageBricks_Auth.
 * A line like "$auth = new PageBricks_Auth($startupParams);"
 * would work fine provided the class resides in the file Auth.php which in
 * turn needs to live inside the folder PageBricks, which in turn must
 * be some way or other part of your include path.  
 * 
 * @package    PageBricks
 * @subpackage Xamples
 * @filesource
 */
/**
 * Autoloader
 * 
 * @param string $classname
 * @return void
 */
function __autoload($classname)
{
	$filepath = strtr($classname,"_", DIRECTORY_SEPARATOR);
	$filepath .= '.php';
	require $filepath;
}